package com.java.thread.join;

public class JoinThread extends Thread {

    @Override
    public void run(){
        for(int i=0;i<10;i++){
            try {
                Thread.sleep((long)(Math.random()*1000));
            } catch (InterruptedException e) {
                e.printStackTrace();
            }
            System.out.println(i);
        }
    }
}
